<%@ Page Language="C#" MasterPageFile="app-frame.master" AutoEventWireup="true" CodeFile="ReportSQL.aspx.cs" Inherits="app_frame_Default2" Title="MaxBlox" %>
<asp:Content ID="Content3" ContentPlaceHolderID="ContentPlaceHolder3" Runat="Server">
    <table style="width: 100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
            <td>
                <asp:Label ID="lblMessage" runat="server" CssClass="defaultFont" Font-Size="X-Small" ForeColor="Black"></asp:Label></td>
        </tr>
        <tr>
        <td class="Dynamic_PageHeaderRow">
            <asp:Label ID="lblHeader" runat="server" Text="Query for Report - Add" Width="207px"></asp:Label></td>
        </tr>
        <tr>
            <td id="td_Page_ToopTip" runat="server">
            </td>
        </tr>
        <tr>
            <td>
               
            </td>
        </tr>
    </table>
    <table id="TABLE1" style="width: 100%" cellpadding="0" cellspacing="0" border="0" runat="server">
        <tr>
            <td style="width: 166px">
                <asp:Label ID="lbl_id" runat="server" Text="Query Id" Visible="False" CssClass="controlLabelFont"></asp:Label></td>
            <td>
                <asp:TextBox ID="p_sy_report_sql_report_base_id" runat="server" Enabled="False"
                    Width="238px" Visible="False" CssClass="controlFont"></asp:TextBox></td>
        </tr>
        <tr>
            <td style="width: 166px">
                <asp:Label ID="Label2" runat="server" Text="Query Name" CssClass="controlLabelFont"></asp:Label></td>
            <td>
                <asp:TextBox ID="p_sy_report_sql_report_base_name" runat="server"
                    Width="238px" CssClass="controlFont"></asp:TextBox></td>
        </tr>
        <tr>
            <td style="width: 166px">
                <asp:Label ID="Label1" runat="server" Text="Query Description" CssClass="controlLabelFont"></asp:Label></td>
            <td>
                <asp:TextBox ID="p_sy_report_sql_report_base_desc" runat="server"
                    Rows="3" TextMode="MultiLine" Width="238px" CssClass="controlFont"></asp:TextBox></td>
        </tr>
        <tr>
            <td style="width: 166px">
                <asp:Label ID="primary_object_id" runat="server" Text="Primary Object" CssClass="controlLabelFont"></asp:Label></td>
            <td>
                <asp:DropDownList ID="p_sy_report_sql_primary_object_id" runat="server" Width="238px" CssClass="controlFont">
                </asp:DropDownList></td>
        </tr>
        <tr>
            <td style="width: 166px;">
                <asp:Label ID="Label5" runat="server" Text="Parameters" CssClass="controlLabelFont"></asp:Label></td>
            <td>
                <asp:TextBox ID="p_sy_report_sql_report_base_param" runat="server"
                    Rows="3" TextMode="MultiLine" Width="449px" CssClass="controlFont"></asp:TextBox><br />
                <asp:Label ID="lblP" runat="server" Text="Parameters Syntax: [parameter_name][table_name.field_name]=default value. Parameters are separated by comma(,) and enclosed with square brackets[]." CssClass="controlLabelFont"></asp:Label></td>
        </tr>
        <tr>
            <td style="width: 166px;">
                <asp:Label ID="Label3" runat="server" Text="Query" CssClass="controlLabelFont"></asp:Label></td>
            <td>
                <asp:TextBox ID="p_sy_report_sql_report_base_sql" runat="server"
                    Rows="5" TextMode="MultiLine" Width="449px" CssClass="controlFont"></asp:TextBox><br />
                <asp:Label runat="server" ID="lblQ" CssClass="controlLabelFont" Text="Use the parameter name enclosed with $ symbol in the Query. For example, select * from table_name where field_id=$parameter_name$."></asp:Label></td>
        </tr>
        <tr><td style="width: 166px;">
            <asp:Label ID="Label4" runat="server" Text="Owner" CssClass ="Controllabelfont"></asp:Label></td><td id="tdownerid" runat="server"><asp:DropDownList ID="p_sy_report_sql_owner_id_dd" runat="server" CssClass="controlFont" Visible="False"></asp:DropDownList>
                <asp:TextBox ID="txt_p_sy_report_sql_owner_id" runat="server" CssClass="controlFont"></asp:TextBox></td></tr>
        <tr class="Dynamic_HtmlTableBottom">
            <%--<td style="width: 166px">
            </td>--%>
            <td colspan="2">
                <asp:Button ID="btnCheck" runat="server" UseSubmitBehavior="false" OnClick="btnCheck_Click" Text="Parse" OnClientClick="javascript:disableThis('ctl00_ContentPlaceHolder3_btnCheck','Parsing....'); disableThisNoValidation('ctl00_ContentPlaceHolder3_btnSave','Save'); disableThisNoValidation('ctl00_ContentPlaceHolder3_btnUpdate','Save')"/>
                <asp:Button ID="btnSave" runat="server" UseSubmitBehavior="true" OnClick="btnSave_Click"  Text="Save" OnClientClick="javascript:disableThis('ctl00_ContentPlaceHolder3_btnSave','Saving....'); disableThis('ctl00_ContentPlaceHolder3_btnCheck','Parse');" />
                <asp:Button ID="btnUpdate" runat="server" UseSubmitBehavior="true" OnClick="btnUpdate_Click" Text="Save" OnClientClick="javascript:disableThis('ctl00_ContentPlaceHolder3_btnUpdate','Saving....'); disableThis('ctl00_ContentPlaceHolder3_btnCheck','Parse');" />
                <asp:Button ID="btnReset" runat="server" Text="Reset" UseSubmitBehavior="false" OnClick="btnReset_Click"  /></td>
                </tr>
    </table>
                <asp:HiddenField ID="p_sy_report_sql_af_row_id" runat="server" />
                <asp:HiddenField ID="p_sy_report_sql_created_at" runat="server"></asp:HiddenField>
                <asp:HiddenField ID="p_sy_report_sql_created_by" runat="server"></asp:HiddenField>
    <asp:HiddenField ID="p_sy_report_sql_owner_id" runat="server" />
    <%--<asp:HiddenField ID="p_sy_report_sql_owner_id" runat="server" />--%>
</asp:Content>

